package com.henau.domain;

import lombok.Data;

import java.util.Date;
import java.util.Objects;


public class Car {
    private int id;
    private int carTeamId;
    private String carID;//车牌号
    private String carColor;//车牌颜色
    private String carType;//车辆类型
    private String carCompany;//所属公司
    private int carPeopleTotal;//车辆核载人数
    private String carCondition;//车辆运行状态
    private String driver;//司机姓名
    private String driverTel;//司机电话
    private String driverPw;//司机端密码
    private String carProvince;//车籍地（省）
    private String carCity;//车籍地（市）
    private String carCounty;//车籍地（县）
    private String carBrand;//车辆品牌
    private String carChassisNum;//车架号
    private Date carBirthday;//车辆出厂日期
    private String carGrade;//车辆等级
    private String carDrivingLicense;//行驶证
    private Date carDLExpirationTime;//行驶证到期时间
    private String carRoadLicense;//道路运输许可证
    private Date carRLExpirationTime;//道路运输许可证到期时间
    private String carModel;//型号

    public Car(int id) {
        this.id = id;
    }

    public int getCarTeamId() {
        return carTeamId;
    }

    public void setCarTeamId(int carTeamId) {
        this.carTeamId = carTeamId;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        Car car = (Car) o;
        return carPeopleTotal == car.carPeopleTotal &&
                Objects.equals(carID, car.carID) &&
                Objects.equals(carColor, car.carColor) &&
                Objects.equals(carType, car.carType) &&
                Objects.equals(carCompany, car.carCompany) &&
                Objects.equals(carCondition, car.carCondition) &&
                Objects.equals(driver, car.driver) &&
                Objects.equals(driverTel, car.driverTel) &&
                Objects.equals(driverPw, car.driverPw) &&
                Objects.equals(carProvince, car.carProvince) &&
                Objects.equals(carCity, car.carCity) &&
                Objects.equals(carCounty, car.carCounty) &&
                Objects.equals(carBrand, car.carBrand) &&
                Objects.equals(carChassisNum, car.carChassisNum) &&
                Objects.equals(carBirthday, car.carBirthday) &&
                Objects.equals(carGrade, car.carGrade) &&
                Objects.equals(carDrivingLicense, car.carDrivingLicense) &&
                Objects.equals(carDLExpirationTime, car.carDLExpirationTime) &&
                Objects.equals(carRoadLicense, car.carRoadLicense) &&
                Objects.equals(carRLExpirationTime, car.carRLExpirationTime) &&
                Objects.equals(carModel, car.carModel);
    }

    @Override
    public int hashCode() {
        return Objects.hash(carID, carColor, carType, carCompany, carPeopleTotal, carCondition, driver, driverTel, driverPw, carProvince, carCity, carCounty, carBrand, carChassisNum, carBirthday, carGrade, carDrivingLicense, carDLExpirationTime, carRoadLicense, carRLExpirationTime, carModel);
    }

    public String getCarID() {
        return carID;
    }

    public void setCarID(String carID) {
        this.carID = carID;
    }

    public String getCarColor() {
        return carColor;
    }

    public void setCarColor(String carColor) {
        this.carColor = carColor;
    }

    public String getCarType() {
        return carType;
    }

    public void setCarType(String carType) {
        this.carType = carType;
    }

    public String getCarCompany() {
        return carCompany;
    }

    public void setCarCompany(String carCompany) {
        this.carCompany = carCompany;
    }

    public int getCarPeopleTotal() {
        return carPeopleTotal;
    }

    public void setCarPeopleTotal(int carPeopleTotal) {
        this.carPeopleTotal = carPeopleTotal;
    }

    public String getCarCondition() {
        return carCondition;
    }

    public void setCarCondition(String carCondition) {
        this.carCondition = carCondition;
    }

    public String getDriver() {
        return driver;
    }

    public void setDriver(String driver) {
        this.driver = driver;
    }

    public String getDriverTel() {
        return driverTel;
    }

    public void setDriverTel(String driverTel) {
        this.driverTel = driverTel;
    }

    public String getDriverPw() {
        return driverPw;
    }

    public void setDriverPw(String driverPw) {
        this.driverPw = driverPw;
    }

    public String getCarProvince() {
        return carProvince;
    }

    public void setCarProvince(String carProvince) {
        this.carProvince = carProvince;
    }

    public String getCarCity() {
        return carCity;
    }

    public void setCarCity(String carCity) {
        this.carCity = carCity;
    }

    public String getCarCounty() {
        return carCounty;
    }

    public void setCarCounty(String carCounty) {
        this.carCounty = carCounty;
    }

    public String getCarBrand() {
        return carBrand;
    }

    public void setCarBrand(String carBrand) {
        this.carBrand = carBrand;
    }

    public String getCarChassisNum() {
        return carChassisNum;
    }

    public void setCarChassisNum(String carChassisNum) {
        this.carChassisNum = carChassisNum;
    }

    public Date getCarBirthday() {
        return carBirthday;
    }

    public void setCarBirthday(Date carBirthday) {
        this.carBirthday = carBirthday;
    }

    public String getCarGrade() {
        return carGrade;
    }

    public void setCarGrade(String carGrade) {
        this.carGrade = carGrade;
    }

    public String getCarDrivingLicense() {
        return carDrivingLicense;
    }

    public void setCarDrivingLicense(String carDrivingLicense) {
        this.carDrivingLicense = carDrivingLicense;
    }

    public Date getCarDLExpirationTime() {
        return carDLExpirationTime;
    }

    public void setCarDLExpirationTime(Date carDLExpirationTime) {
        this.carDLExpirationTime = carDLExpirationTime;
    }

    public String getCarRoadLicense() {
        return carRoadLicense;
    }

    public void setCarRoadLicense(String carRoadLicense) {
        this.carRoadLicense = carRoadLicense;
    }

    public Date getCarRLExpirationTime() {
        return carRLExpirationTime;
    }

    public void setCarRLExpirationTime(Date carRLExpirationTime) {
        this.carRLExpirationTime = carRLExpirationTime;
    }

    public String getCarModel() {
        return carModel;
    }

    public void setCarModel(String carModel) {
        this.carModel = carModel;
    }


    public Car() {
    }

    @Override
    public String toString() {
        return "Car{" +
                "id=" + id +
                ", carTeamId=" + carTeamId +
                ", carID='" + carID + '\'' +
                ", carColor='" + carColor + '\'' +
                ", carType='" + carType + '\'' +
                ", carCompany='" + carCompany + '\'' +
                ", carPeopleTotal=" + carPeopleTotal +
                ", carCondition='" + carCondition + '\'' +
                ", driver='" + driver + '\'' +
                ", driverTel='" + driverTel + '\'' +
                ", driverPw='" + driverPw + '\'' +
                ", carProvince='" + carProvince + '\'' +
                ", carCity='" + carCity + '\'' +
                ", carCounty='" + carCounty + '\'' +
                ", carBrand='" + carBrand + '\'' +
                ", carChassisNum='" + carChassisNum + '\'' +
                ", carBirthday=" + carBirthday +
                ", carGrade='" + carGrade + '\'' +
                ", carDrivingLicense='" + carDrivingLicense + '\'' +
                ", carDLExpirationTime=" + carDLExpirationTime +
                ", carRoadLicense='" + carRoadLicense + '\'' +
                ", carRLExpirationTime=" + carRLExpirationTime +
                ", carModel='" + carModel + '\'' +
                '}';
    }

    public Car(int carTeamId, String carID, String carColor, String carType, String carCompany, int carPeopleTotal, String carCondition, String driver, String driverTel, String driverPw, String carProvince, String carCity, String carCounty, String carBrand, String carChassisNum, Date carBirthday, String carGrade, String carDrivingLicense, Date carDLExpirationTime, String carRoadLicense, Date carRLExpirationTime, String carModel) {
        this.carTeamId = carTeamId;
        this.carID = carID;
        this.carColor = carColor;
        this.carType = carType;
        this.carCompany = carCompany;
        this.carPeopleTotal = carPeopleTotal;
        this.carCondition = carCondition;
        this.driver = driver;
        this.driverTel = driverTel;
        this.driverPw = driverPw;
        this.carProvince = carProvince;
        this.carCity = carCity;
        this.carCounty = carCounty;
        this.carBrand = carBrand;
        this.carChassisNum = carChassisNum;
        this.carBirthday = carBirthday;
        this.carGrade = carGrade;
        this.carDrivingLicense = carDrivingLicense;
        this.carDLExpirationTime = carDLExpirationTime;
        this.carRoadLicense = carRoadLicense;
        this.carRLExpirationTime = carRLExpirationTime;
        this.carModel = carModel;
    }
}
